-
Notifications
You must be signed in to change notification settings - Fork 117
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Dev #41
base: master
Are you sure you want to change the base?
Dev #41
Conversation
For embeddedout.c FIXED SORT, new features, additional Update routine Custom commands for these More options for dummy_leds.c for embeddedlinux testing changed embedded8266/esp82xx to most recent subproject Improved UpdateLinearLEDs FIXING SORT_NOTES, adding rotation and shifting options Added new update routine UpdateRotatingLEDs() to embeddedcommon/embeddedout.c with custom commands controling above via web gui Added improved dummy_leds.c to embeddedlinux so can compile to show a ring colorchord2 .conf files changed to my sound sources, IP and LED setup embedded8266/ccconfig.h now allows SORT_NOTES 1 as I fixed the option modified embedded8266/user.cfg changed to my SDK, slowed baud rate for burning as mac needs slower added code to embedded8266/user/custom_commands.c for two additional commands gCOLORCHORD_ADVANCE_SHIFT = 0; gCOLORCHORD_SUPRESS_FLIP_DIR = 1; added code embedded8266/user/user_main.c and embeddedcommon/embeddedcc.c to handle the new features of embeddedout.c new global variable int framecount incremented in NewFrame() and used in the UpdateLinearLEDs and UpdateRotatingLEDs in embeddedcommon/embeddedcc.c replaced Init() and InitColorChord() embeddedcommon/embeddedout.c added three global variables: total_note_a_prev, diff_a_prev and rot_dir so this info will persist between calls to the Update routines. added printfs for debugging (only when using embeddedlinux, not on embedded8266) modified UpdateLinearLEDs() FIXED LIN_WRAPAROUND so ledFreqOUTold is not saved in case LIN_WRAPAROUND 0 computes total of note_peak_amps so can react to overall sound intensity FIXED SORT_NOTES - removed old code from first loops added new sort on local_peak_amp2 after the loop code can be improved to switch between keys TODO allow inc/dec sorting as param TODO sort uses pointer, but need to fix to handle both uint8_t and uint16_t added FEATURE code to rotate the display, speed and direction being controled by by these extern gCOLORCHORD_ADVANCE_SHIFT and gCOLORCHORD_SUPRESS_FLIP_DIR removed old commented out code added UpdateRotatingLEDs() new FEATURE code to rotate one LED at dominant color and amp (as in UpdateSameLEDs) the speed and direction being controled by same parameters as above embeddedcommon/embeddedout.h added extern variables and changed compiler directives embeddedlinux mods of Makefile and ccconfig.h to suit my set up and test improved dummy_leds mods of dummy_leds.c to have a RING option mods of embeddedcc.c added comment is there a tool param? added debug printfs added global framecount
UpdateLinearLEDs can now use LIN_WRAPAROUND while rotating LEDs UpdateRotatingLEDs now has code to have LED arc length proportional to amp2 can have constant intensity or related to amp2
SORT_NOTES is now controllable via web gui 0 no sort, 1 sort inc by freq, 2 sort dec by amps, 3 by amps2 LIN_WRAPAROUND now controllable via web gui 0 no, else yes ESP8266 now running much slower 32 HZ before 200 Hz not sure why. Code shouldn't be that much slower
changes in embeddedout.c to shift computed display around the LED ring by using a modular frame count gFRAMECOUNT_MOD_SHIFT_INTERVAL and putting the shift into global gROTATIONSHIFT added few more comments tidied indents
UpdateLinearLEDs() modified to make a linear pattern on USE_NUM_LIN_LEDS leds then place this pattern as an arc into a ring with NUM_LIN_LEDS leds the placement can be shifted so that it rotates A few more comments. Refactor some names to reflect their purpose better TODO UpdateRotatingLEDs() is almost a special case of UpdateLinearLEDs with a few more improvements they can be combined
Since no sound should give 127 on ADC slider fixed to expand display around that value rather than just multiply added extra column to note display so have note number expanded factor for showing amp and amp2
Woah there's a lot of stuff going on here. @con-f-use I am unfamiliar with how this would work on a project without a pre-existing "dev" branch. Can I safely hit merge then test in post? Also, @bbkiwi one major thing I wanted to note is now esp82xx supports binary websockets, you can transfer full-on binary data. (just fyi) |
I'd test it via Btw. it would've been helpful telling us, that you were working on colorchord all this time, not just the vanilla esp82xx. |
Got it. This may also be the time to add support for RGBY LEDs. |
Also @bbkiwi I think I know why you're having issues with connecting to another station and will work on that. |
Hi @con-f-use Cheers, Bill |
Hi @cnlohr
|
Anyone try merging everything yet? |
gaah I didn't get to testing this tonight. Please try and check. |
I did get to checking the new esp82xx... but... not cc. Also, we really need to make sure cc and esp82xx are updated in pair. |
if I try cc/dev with all my changes using most recent esp82xx/dev overflows by 1292 bytes. ... /home/bill/82XX-projects/colorchord/embedded8266/esp82xx/toolchain/esp_nonos_sdk/lib -o image.elf |
@con-f-use do you mind making sure my merging here won't wreck things up? Also @bbkiwi AFASF#$#(%G#%(G#(#(D@)C(ASD(V I thought we had enough memory recovered in the custom SDK I had pieced together. UGH. |
I wasn't sure if AFASF ... was an acronym or just your left hand going mad :-). Looking issue #35 where make all embedd8286 overflowed by 288 bytes. Note I only have tested my changes to embeddedcommon for embedded8266 (with 18 LEDs) and embeddedlinux. I have not way to try it for the other two embedded devices. |
@bbkiwi are you up for pursuing this again? I don't know any way around it other than manually implementing most of these changes. Is that something I should do? Will you always have a separate trunk without that? |
I'm away from home for a few more days and then will have access to my computer. Might be a good idea to skype to discuss. Both branches on my fork, adddevwork and newfeatures which use slightly modified esp82xx submodule which use your custom sdk have no memory problems.
|
Just wondering... what came of all of this? I thought it was mostly integrated another way. |
colorchord.zip |
Do you mind elaborating more? I don't really understand what happened with this still. |
From what I can see most of the stuff that changed something in esp82xx has been merged into esp82xx. At least cnlohr/esp82xx#77 shows no diff and is a PR from head of his esp82xx branch to ours. |
Hi @cnlohr and @con-f-use, I lost track a bit about all this and had not done much for a long time, but just recently started again. Also my repo was screwed up so a clone of it couldn't bring in the submodule using my fork of exp82xx correctly. However I think I've fixed that all. In my cc fork bbkiwi@0717767 I'm using newfeatures branch which uses esp82xx submodule from my fork of esp82xx at the top of branch tmp. I've compared bbkiwi/esp82xx@75b0773 with cnlohr/esp82xx@b7fc6f637ae9c3302195f54572e1cc5d007124f1and there are some differences but the only one I notice that might affect the interaction of ADC and wifi is that I call StartHPATimer in GoAP in commonservices.c. Other changes I made were to add an option to assign fixed IPs. Other changes are more cosmetic. At this point using my fork on branch newfeatures is working well and I will probably continue using it. It is stable tested on 5 Nodemcu and Weimos too, I can connect to a specified IP, I've used it with LED rings from 16 to 60. I've added a 'glitch' filter to get rid of interferance of sockets with the ADC. I'm not sure it will be easy to make pull requests for these as the changes are not easily isolated. |
Hi @cnlohr and @con-f-use