Open nikita890-art opened 2 years ago
Hi,
A few question :
This won't work on spike i guess, as it does not implement the same peripherals.
Is there any way I can get the message printed? @Dolu1990
I would say, the best is to scope the uart to understand the symptoms better.
Are you sure the frequency of the clock match the one specified at the SpinalHDL generation ? The uart divider get a value depending on it.
Hi... I am trying to execute this code, . . . void print(const charstr){ while(str){ uart_write(UART,str); str++; } } void println(const charstr){ print(str); uart_write(UART,'\n'); } void delay(uint32_t loops){ for(int i=0;i<loops;i++){ int tmp = GPIO_A->OUTPUT; } } int main() { char message[1024]="what's your name\n"; GPIO_A->OUTPUT_ENABLE = 0x0000000F; GPIO_A->OUTPUT = 0x00000001; println("what's your name"); . . . When I dump this code in the arty board, it gives some random output like a special character. So, I try to run it on spike and I get a segmentation fault.
What can I do?
Note: This is just the snippet of the code. The actual code is kinda big. I dont think the entire code matters as I dont really use any println statement other than this one in my code but just in case if needed, I can upload it in the drive.