Announcement

Collapse
No announcement yet.

EVE Stack Overflow Trying to use sys_SetTimerEvent()

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • pauleilio
    replied
    Hi,

    I am still looking at through your code to see how it can be sped up a bit.

    I haven't used I2C1_AckPoll() before but I will try to find an example that will help. I'll update you as soon as I find out more information.

    Best regards

    Paul

    Leave a comment:


  • weirdwolf
    replied
    Hi again paul, i was wondering if you would happen to know how to use the I2C1_AckPoll(); function, or where to find an example on how to use it, because i've been looking around the forum for some kind of example, but I'm not having any luck finding anything, and I'm in need of an ACK polling function for the project.

    Leave a comment:


  • pauleilio
    replied
    Thank you,

    I will see what can be done.

    Best regards

    Paul

    Leave a comment:


  • weirdwolf
    replied
    Absolutely, and thanks a lot for the quick responses.

    The functions for updating the spectrum values (the I2C comm one) and the function for updating the spectrum itself are updateFFT() and updateVisualizer(), so you don't have to guess, with the laggy form function being HomeScreen().
    Attached Files

    Leave a comment:


  • pauleilio
    replied
    Hi,

    Would you be able to send me what you have now without the timers and I will see what can be done about reducing the laggy feel.

    Best regards

    Paul

    Leave a comment:


  • weirdwolf
    replied
    while it does run without the timers, it becomes extremely "laggy" because it's busy communicating with my Teensy controller all the time, I tried using the sys_T() function to make a timer via an IF statement, but got the samme "laggy" behavior, while it's on the HomeScreen form the rapid updates and I2C communication causes the entire form to just be very slow.

    I've given up on the sys_SetTimerEvent and sys_SetTimer functions, but i still feel like i need some way to slow down the very frequent I2C and spectrum updates, since they're the ones that seem to slow the form down, I'm just not sure how to stop them from slowing down the form, while still keeping their updates frequent enough that they're actually useful.
    Last edited by weirdwolf; 22 May 2020, 06:38 AM.

    Leave a comment:


  • pauleilio
    replied
    Hi,

    I have tried your project and ran into the same issue. We're still testing it at the moment,

    I personally think it would work better without the timers and the updates were done in the mainloop and also the spectrum would benefit from only updating bars that have changed in value so that there is less time spent updating all the bars if some haven't changed.

    Best regards

    Paul

    Leave a comment:


  • weirdwolf
    replied
    Personally i think the problem lies with the Timer functions, is there any other way to implement a Timer, say like the arduinos Millis() function?

    Leave a comment:


  • weirdwolf
    started a topic EVE Stack Overflow Trying to use sys_SetTimerEvent()

    EVE Stack Overflow Trying to use sys_SetTimerEvent()

    Hi,

    quick edit: I'm using aGen4-ULCD-43DCT-CLB, since i forgot to mention that.

    I've been trying now for the past 2 days to get this to work, without any luck, I'm trying to make a control panel for an amplifier with a digitally controlled equalizer, with a visualizer shown on screen, however I'm having trouble getting the Visualizer to properly work, and have now hit an EVE Stack Overflow when trying to run my application, so i need help.

    The basic principle for how i'm trying to get the visualizer to work is that i'm using a Teensy 4.0 Microcontroller board to run an FFT on my audio signal, which is then sent to the Diablo16 display via I2C, that part i can get working just fine, and i got the Spectrum working as a Visualizer as well, at least in my test sketch (Test sketch is attached in SpectrumTestSketch.zip), from there i thought great, i'll go ahead and implement that into my application, and troubleshoot any issues that pop up from there, and i tried, but it just, won't work and i can't for the life of me figure out why.

    I'm trying to update the spectrum & relevant I2C values through sys_SetTimerEvent(), and then starting the timers in question when the correct form is running, so they don't try and run when i'm in my menu forms, but seemingly no matter what i do i can't get it to work, at first it just didn't run, then i got it to run once if i went into my menu form and back, and now the application crashes every time it tries to run.

    I've attached my Spectrum Test Sketch (as mentioned earlier) and my main application (SvendeProjekt.zip) to this post, everything relevant to the sketches should be in there.

    if anyone can take a look at this and at the very least point me in the correct direction i would be extremely thankful.

    Regards,
    Weirdwolf.
    Attached Files
    Last edited by weirdwolf; 20 May 2020, 08:35 AM.
Working...
X