Search found 26 matches

by rolanddixon
Tue Nov 02, 2021 8:06 am
Forum: General Support
Topic: Terminating a thread from another thread - is it possible?
Replies: 5
Views: 8181

Re: Terminating a thread from another thread - is it possible?

Hi,

I know this is an old thread, and chibios has moved on a bit since, but I was wondering how one could reuse the stack of a thread that has exited.

Is the code below code safe to use?

monitoring thread:


chSysLock();
pThd->flags |= CH_FLAG_TERMINATE;
chSemResetI(pSemaphore, 0);
chSysUnlock ...
by rolanddixon
Tue Oct 26, 2021 2:59 pm
Forum: Small Change Requests
Topic: Allow forward declaration of chibios hal structs
Replies: 8
Views: 11557

Re: Allow forward declaration of chibios hal structs

Hi Giovanni,

It has been a while but here is a patch for the i2c driver and config typedefs (hal_i2c_config and hal_i2c_driver).

I have tested the builds for the STM32 testhal projects.
by rolanddixon
Wed Jun 23, 2021 3:34 pm
Forum: Small Change Requests
Topic: Allow forward declaration of chibios hal structs
Replies: 8
Views: 11557

Re: Allow forward declaration of chibios hal structs

Here are the can, uart and serial patches.
These are the peripherals that I am using at the moment. I will upload the other when I use the peripherals which won't be for a while.
by rolanddixon
Wed Jun 23, 2021 11:15 am
Forum: Small Change Requests
Topic: Allow forward declaration of chibios hal structs
Replies: 8
Views: 11557

Re: Allow forward declaration of chibios hal structs

Here is the first hal_serial patch. I have applied it and built all code in "testhal". All the arm based code compiles file. Some of the AVR based code fails but not due to the changes I made. I probably have a mismatch of version of the avr-gcc compiler.

I have zipped the patch along with the ...
by rolanddixon
Wed Jun 23, 2021 9:18 am
Forum: Small Change Requests
Topic: Allow forward declaration of chibios hal structs
Replies: 8
Views: 11557

Re: Allow forward declaration of chibios hal structs

Ok, yes. I'll submit one patch at a time per driver if that is OK with you.

Roland
by rolanddixon
Tue Jun 22, 2021 10:33 am
Forum: Small Change Requests
Topic: Allow forward declaration of chibios hal structs
Replies: 8
Views: 11557

Allow forward declaration of chibios hal structs

Hi All,

This is a fairly simple request and I do not mind submitting a patch for it but I thought I would ask as it could be against a previous design decision.

I will use the SerialConfig as an example. Currently the structure is defined as:

typedef struct
{
uint32_t speed;
..&#46 ...
by rolanddixon
Mon Jun 21, 2021 12:17 pm
Forum: STM32 Support
Topic: Virtual control interface via semihosting
Replies: 12
Views: 18621

Re: Virtual control interface via semihosting

This maybe an old thread, but for anyone stuck with semihosting with chibios and has landed here in a frantic google search, then there are a couple of things that need to be done to get it up and running for file I/O specifically. Interactions with stdin, stdout and stderr should work out the box ...
by rolanddixon
Wed Mar 29, 2017 2:25 pm
Forum: Development and Feedback
Topic: [TALK] Problems with Cortex-M7
Replies: 39
Views: 99983

Re: [TALK] Problems with Cortex-M7

Nice, thank you. That does clear a few things up.
by rolanddixon
Wed Mar 29, 2017 10:20 am
Forum: Development and Feedback
Topic: [TALK] Problems with Cortex-M7
Replies: 39
Views: 99983

Re: [TALK] Problems with Cortex-M7

Hi All. I would just like to summarise what I understand by these posts, please let me know if I am wrong...

1) Cache handling is NOT completely transparent and the user will require some knowledge of the memory segments before setting aside buffers to be used by the DMA.

2) Cache invalidation ...