[fpc-devel] Problems with fpioctl on ARM debian linux and FPC2.6
sfischer at basis.biz
Tue Jun 19 20:56:34 CEST 2012
after some experiments, tx.. and rx_buf_ptr has to be 64 bits. On fps on arm, the pointer type is translated to 32 Bits.
Ludo's suggestions to use qword (64Bit) is correct.
Is there a possibility to use pointer type with 64 Bits? How ?
spi_ioc_transfer_t = record
tx_buf_ptr,dummytx : pointer; (* <------------ 64 Bits dummytx / dummyrx for spaceing *)
rx_buf_ptr,dummyrx : pointer;
len : longword;
speed_hz : longword;
delay_usecs : word;
bits_per_word : byte;
cs_change : byte;
pad : longword;
Am 19.06.2012 um 19:04 schrieb Stefan Fischer:
> I've changed to following:
> added packrecord c
> flipped speed_hz and delay_usec fields
> same problem.
> I don't know whats really wrong.
> Is there any debug possibility?
> Am 19.06.2012 um 15:24 schrieb Jonas Maebe:
>> Henry Vermaak wrote on Tue, 19 Jun 2012:
>>> Also, the buffers need to be u64. Is the pointer type in pascal always 64 bit?
>> u64 is defined as "unsigned long". "unsigned long" is the same size as a pointer on Linux.
>> fpc-devel maillist - fpc-devel at lists.freepascal.org
> fpc-devel maillist - fpc-devel at lists.freepascal.org
More information about the fpc-devel