Click here to Skip to main content
15,892,059 members

Welcome to the Lounge

   

For discussing anything related to a software developer's life but is not for programming questions. Got a programming question?

The Lounge is rated Safe For Work. If you're about to post something inappropriate for a shared office environment, then don't post it. No ads, no abuse, and no programming questions. Trolling, (political, climate, religious or whatever) will result in your account being removed.

 
GeneralRe: Do you remember that time? Pin
theoldfool18-Dec-21 9:33
professionaltheoldfool18-Dec-21 9:33 
GeneralRe: Do you remember that time? Pin
Greg Utas18-Dec-21 9:53
professionalGreg Utas18-Dec-21 9:53 
GeneralRe: Do you remember that time? Pin
DRHuff18-Dec-21 11:28
DRHuff18-Dec-21 11:28 
GeneralRe: Do you remember that time? Pin
Vivi Chellappa18-Dec-21 13:48
professionalVivi Chellappa18-Dec-21 13:48 
GeneralRe: Do you remember that time? Pin
Slow Eddie19-Dec-21 7:34
professionalSlow Eddie19-Dec-21 7:34 
QuestionWould you release this or not? Pin
honey the codewitch18-Dec-21 0:59
mvahoney the codewitch18-Dec-21 0:59 
AnswerRe: Would you release this or not? Pin
0x01AA18-Dec-21 1:17
mve0x01AA18-Dec-21 1:17 
GeneralRe: Would you release this or not? Pin
honey the codewitch18-Dec-21 1:21
mvahoney the codewitch18-Dec-21 1:21 
It's not a matter of finding the right speed unfortunately. It's a matter of finding *where* it's too fast. I have no idea what needs to be slowed down. I've tried slowing down the CS line change and DC line changes, but no dice. It's bizarre. I'm not really sure what else to try. I've also tried disabling these particular optimizations by themselves:

C++
inline static void write_raw8(uint8_t value) FORCE_INLINE {
#ifdef OPTIMIZE_ESP32
    *_spi_mosi_dlen = 7;
    *_spi_w = value;
    *_spi_cmd = SPI_USR;
    while (*_spi_cmd & SPI_USR);
#elif defined(OPTIMIZE_AVR)
    SPDR=(C); 
    while (!(SPSR&_BV(SPIF)));
#else // !OPTIMIZE_ESP32
    spi.transfer(value);
#endif // !OPTIMIZE_ESP32
}


When I do that, but I keep the optimized line changes, I get the same problem.
When I unoptimize the line changes, but keep this optimized, same problem.
Only when I unoptimize both does the problem go away.

The thing to remember, is this optimized code works on boards that are well constructed.
Real programmers use butterflies

GeneralRe: Would you release this or not? Pin
0x01AA18-Dec-21 1:31
mve0x01AA18-Dec-21 1:31 
GeneralRe: Would you release this or not? Pin
honey the codewitch18-Dec-21 2:38
mvahoney the codewitch18-Dec-21 2:38 
AnswerRe: Would you release this or not? Pin
Mike Hankey18-Dec-21 1:33
mveMike Hankey18-Dec-21 1:33 
GeneralRe: Would you release this or not? Pin
honey the codewitch18-Dec-21 2:36
mvahoney the codewitch18-Dec-21 2:36 
AnswerRe: Would you release this or not? Pin
Jo_vb.net18-Dec-21 2:23
mvaJo_vb.net18-Dec-21 2:23 
GeneralRe: Would you release this or not? Pin
bmarstella20-Dec-21 1:01
bmarstella20-Dec-21 1:01 
AnswerRe: Would you release this or not? PinPopular
Randor 18-Dec-21 1:44
professional Randor 18-Dec-21 1:44 
AnswerRe: Would you release this or not? Pin
theoldfool18-Dec-21 2:28
professionaltheoldfool18-Dec-21 2:28 
AnswerRe: Would you release this or not? Pin
dandy7218-Dec-21 4:44
dandy7218-Dec-21 4:44 
GeneralRe: Would you release this or not? Pin
honey the codewitch18-Dec-21 5:15
mvahoney the codewitch18-Dec-21 5:15 
AnswerRe: Would you release this or not? Pin
kmoorevs18-Dec-21 6:03
kmoorevs18-Dec-21 6:03 
GeneralRe: Would you release this or not? Pin
honey the codewitch18-Dec-21 6:04
mvahoney the codewitch18-Dec-21 6:04 
AnswerRe: Would you release this or not? Pin
Gerry Schmitz18-Dec-21 6:30
mveGerry Schmitz18-Dec-21 6:30 
GeneralRe: Would you release this or not? Pin
honey the codewitch18-Dec-21 6:31
mvahoney the codewitch18-Dec-21 6:31 
GeneralRe: Would you release this or not? Pin
Gerry Schmitz18-Dec-21 6:44
mveGerry Schmitz18-Dec-21 6:44 
GeneralRe: Would you release this or not? Pin
honey the codewitch18-Dec-21 7:18
mvahoney the codewitch18-Dec-21 7:18 
AnswerRe: Would you release this or not? Pin
Luc Pattyn18-Dec-21 11:38
sitebuilderLuc Pattyn18-Dec-21 11:38 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.