Sasa Vilic wrote: > Is it possible in EMC to write HAL components which is composed of more > basic components like and, not, or, etc.? For example: I want to write one > component which has input and output pins, and inside of this component I > use existing HAL components, to implement functionality. This component can > be seen as a "Black-Box" and can be used easily again, without writing all > it's internal structure in config files. > > I was looking at THC design, and I think that this could be devided in > (sub)components, but I don't know if that is supported by EMC. If it's not, > it would be nice to have that, because writing some HAL configuration (like > THC) would be much much easier. > I'm not sure what you are looking for, but FPGAs use something like this. They call it a "LUT", ie. look up table. Assuming 4 inputs, you can fill a 16 x 1 bit memory with 16 values of 1 or zero, and address the desired result with 4 inputs. You can map a variety of and, or, xor, not, etc. functions into the 16 values. For instance, you might have 2 2-input and gates feeding a 2-input or gate. That can all be done with one 4-input LUT. The 16-bit pattern to set the logic function could be a HAL parameter, and set with a setp command. Such a HAL component wouldn't be real hard to write, and ought to be fairly efficient.
Jon ------------------------------------------------------------------------------ OpenSolaris 2009.06 is a cutting edge operating system for enterprises looking to deploy the next generation of Solaris that includes the latest innovations from Sun and the OpenSource community. Download a copy and enjoy capabilities such as Networking, Storage and Virtualization. Go to: http://p.sf.net/sfu/opensolaris-get _______________________________________________ Emc-users mailing list Emc-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/emc-users