[fpc-devel] Problems with fpioctl on ARM debian linux and FPC2.6
Henry Vermaak
henry.vermaak at gmail.com
Tue Jun 19 15:21:12 CEST 2012
On 19 June 2012 14:17, Jonas Maebe <jonas.maebe at elis.ugent.be> wrote:
>
> Stefan Fischer wrote on Tue, 19 Jun 2012:
>
>
>> My code snipet is below:
>>
>> spi_ioc_transfer_t = record
>> tx_buf_ptr : pointer;
>> rx_buf_ptr : pointer;
>> len : longword;
>> delay_usec : word;
>> speed_hz : longword;
>> bits_per_word : byte;
>> cs_change : byte;
>> pad : longword;
>> end;
>
>
> The speed_hz and delay_usec fields are switched around. Furthermore, make
> sure to add add {$packrecords C} to guarantee the same alignment as in a C
> compiler.
Also, the buffers need to be u64. Is the pointer type in pascal always 64 bit?
Henry
More information about the fpc-devel
mailing list